Next Article in Journal
A Modified Inertial Parallel Viscosity-Type Algorithm for a Finite Family of Nonexpansive Mappings and Its Applications
Next Article in Special Issue
A Formulation for the Stochastic Multi-Mode Resource-Constrained Project Scheduling Problem Solved with a Multi-Start Iterated Local Search Metaheuristic
Previous Article in Journal
On Solvability of Fractional (p,q)-Difference Equations with (p,q)-Difference Anti-Periodic Boundary Conditions
Previous Article in Special Issue
A Global Neighborhood with Hill-Climbing Algorithm for Fuzzy Flexible Job Shop Scheduling Problem
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Metaheuristic Optimization for Improving Weed Detection in Wheat Images Captured by Drones

by
El-Sayed M. El-Kenawy
1,*,
Nima Khodadadi
2,
Seyedali Mirjalili
3,4,*,
Tatiana Makarovskikh
5,
Mostafa Abotaleb
5,
Faten Khalid Karim
6,
Hend K. Alkahtani
7,*,
Abdelaziz A. Abdelhamid
8,
Marwa M. Eid
9,
Takahiko Horiuchi
10,
Abdelhameed Ibrahim
11 and
Doaa Sami Khafaga
6
1
Department of Communications and Electronics, Delta Higher Institute of Engineering and Technology, Mansoura 35111, Egypt
2
Department of Civil and Environmental Engineering, Florida International University, Miami, FL, USA
3
Centre for Artificial Intelligence Research and Optimization, Torrens University Australia, Fortitude Valley, Brisbane QLD 4006, Australia
4
Yonsei Frontier Lab, Yonsei University, Seoul 03722, Republic of Korea
5
Department of System Programming, South Ural State University, Chelyabinsk, Russia
6
Department of Computer Sciences, College of Computer and Information Sciences, Princess Nourah bint Abdulrahman University, P.O. Box 84428, Riyadh 11671, Saudi Arabia
7
Department of Information Systems, College of Computer and Information Sciences, Princess Nourah bint Abdulrahman University, P.O. Box 84428, Riyadh 11671, Saudi Arabia
8
Department of Computer Science, Faculty of Computer and Information Sciences, Ain Shams University, Cairo 11566, Egypt
9
Faculty of Artificial Intelligence, Delta University for Science and Technology, Mansoura, Egypt
10
Graduate School of Engineering, Chiba University, 1-33 Yayoi-cho, Inage-ku, Chiba 263-8522, Japan
11
Computer Engineering and Control Systems Department, Faculty of Engineering, Mansoura University, Mansoura 35516, Egypt
*
Authors to whom correspondence should be addressed.
Mathematics 2022, 10(23), 4421; https://doi.org/10.3390/math10234421
Submission received: 17 August 2022 / Revised: 17 November 2022 / Accepted: 20 November 2022 / Published: 23 November 2022
(This article belongs to the Special Issue Metaheuristic Algorithms)

Abstract

:
Background and aim: Machine learning methods are examined by many researchers to identify weeds in crop images captured by drones. However, metaheuristic optimization is rarely used in optimizing the machine learning models used in weed classification. Therefore, this research targets developing a new optimization algorithm that can be used to optimize machine learning models and ensemble models to boost the classification accuracy of weed images. Methodology: This work proposes a new approach for classifying weed and wheat images captured by a sprayer drone. The proposed approach is based on a voting classifier that consists of three base models, namely, neural networks (NNs), support vector machines (SVMs), and K-nearest neighbors (KNN). This voting classifier is optimized using a new optimization algorithm composed of a hybrid of sine cosine and grey wolf optimizers. The features used in training the voting classifier are extracted based on AlexNet through transfer learning. The significant features are selected from the extracted features using a new feature selection algorithm. Results: The accuracy, precision, recall, false positive rate, and kappa coefficient were employed to assess the performance of the proposed voting classifier. In addition, a statistical analysis is performed using the one-way analysis of variance (ANOVA), and Wilcoxon signed-rank tests to measure the stability and significance of the proposed approach. On the other hand, a sensitivity analysis is performed to study the behavior of the parameters of the proposed approach in achieving the recorded results. Experimental results confirmed the effectiveness and superiority of the proposed approach when compared to the other competing optimization methods. The achieved detection accuracy using the proposed optimized voting classifier is 97.70%, F-score is 98.60%, specificity is 95.20%, and sensitivity is 98.40%. Conclusion: The proposed approach is confirmed to achieve better classification accuracy and outperforms other competing approaches.

1. Introduction

Climate change and worldwide population expansion are exerting significant pressure on agriculture to expand food production in terms of quality and quantity. Because the global population is expected to grow to nine billion people by 2050, agricultural production will need to quadruple to keep up [1]. Plant diseases, pests, and weed infestation pose enormous problems to agriculture [2,3,4,5]. Weeds are unwelcome plants that take nutrients from the soil, compete with profitable crops for light, water, and other resources, and spread by seeds or rhizomes. Weeds, pests, and diseases diminish crop yields and quality, reducing the amount of food, fiber, and biofuel that can be produced. Losses might be sudden or long-term, but on average, 42% of a few key food crops’ productions is lost.
To achieve reasonable weed control and increased crop output, farmers invest billions of dollars every year in weed management. It is, therefore, critical to managing weeds in horticulture crops, as failure to do such results in lower yields and product quality [6]. If not handled properly, the employment of chemical and cultural control methods might negatively affect the ecosystem. Weed control will be more successful and long-lasting with low-cost technology for identifying and mapping weeds early in their life cycle. Crop diseases and pests can be reduced, and crop yields can be increased by as much as 34% when early weed management is used [7]. Weeds may be managed in various ways, all of which take environmental considerations into account. Image processing is one of the most promising of these methods. Unmanned aerial vehicles (UAVs) are used in image processing to monitor crops and capture images of potential weeds in the fields. Due to their capacity to cover enormous areas quickly, UAVs have been proven to be helpful in agriculture because they do not create soil compaction or damage in the fields [8]. It is still a challenge to turn data gathered by UAVs into relevant information. Due to the manual labor required for segment size tweaking, feature selection, and rule-based classifier building, conventional data gathering and classification cannot be automated.
With the goal of increasing crop productivity while decreasing the prevalence of unwanted weeds, agricultural mechanization has emerged as the leading research field [9]. The intelligent spraying system relies heavily on accurately identifying weed plants to maximize agricultural yield [10]. Many machine learning-based algorithms have been developed for weed identification, making it a promising area of study for data scientists [11]. Many scientists used computer vision algorithms to categorize agricultural, and weed plants [12]. Various deep learning and hand-crafted models have also been published and have made substantial contributions [13]. Color classification strategies for perennial weed identification [12], CNN-based method/approach for distinguishing sugar beet plants from weeds [14], deep convolutional neural network (DNN) [15], Gabor wavelets and neural network [16], hyperspectral imaging with wavelet analysis [17], decision trees, and artificial neural network [18] have all been proposed for the classification of weeds. The agriculture industry has benefited greatly from these strategies, which have produced extraordinary results. Better weed plant classification, however, requires more advanced and efficient methodologies to boost the accuracy of weed detection.
In this work, a publicly available wheat images dataset is employed as the overarching inspiration for this research. This dataset is utilized for training a deep neural network through transfer learning and feature extraction. In addition, to boost the classification accuracy of weed images, a new optimization algorithm is proposed to optimize the parameters of a new voting ensemble classifier composed of neural network (NN), k-nearest neighbors (KNN), and support vector machine (SVM) machine learning models. Moreover, a binary optimizer is proposed to optimize the feature selection process to select the best set of features. To evaluate the performance of the proposed methodology, a set of evaluation criteria is adopted to assess the effectiveness of the feature selection algorithm and an optimized voting ensemble model. On the other hand, statistical tests, such as the one-way analysis of variance and the Wilcoxon signed-rank test, are conducted to evaluate the significance and statistical difference of the proposed methodology. The recorded results are compared to those of other algorithms to show the superiority of the proposed approach.
This paper is structured in terms of five sections. Section 1 presents the introduction of the problem addressed in this paper and a summary of the proposed solution. Section 2 discusses the main milestones in the literature related to the task of weed detection. The materials and methods employed in the proposed solution are presented in Section 3. The proposed algorithms and solutions are explained in Section 4, and the experimental results are discussed in Section 5. Finally, the conclusions are presented in Section 6.

2. Literature Review

Weed identification using machine learning and image analysis has been increasingly popular in recent years, and the research presented here examines some of the most notable examples. Weed maps may be generated using several classification methods using UAV images [19,20,21,22]. However, recent state-of-the-art publications [23] reveal that machine learning algorithms are superior to traditional parametric methods in terms of accuracy and efficiency when dealing with complex data. The random forest (RF) classifier is one of the most well-liked machine learning algorithms for use in remote sensing [24]. This is because of its high generalization performance and fast processing time. The classification of high-resolution UAV images and agricultural mapping with RF has been proven beneficial. SVM is another well-known machine learning classifier [25,26,27,28], and it has been widely used to categorize weeds and crops. Meanwhile, the authors in [29] employed the KNN method to identify spreading thistles in sugar beet fields. New efforts on a machine learning-based approach for weed detection are summarized in Table 1.
In [25], the authors create a land cover map of the Riverina region in New South Wales, Australia, covering a total area of 6200 km 2 , to identify and categorize perennial crops in this vast region. They used object-based image analysis with supervised support vector machine classification to improve precision. After analyzing the data, they determined that the accuracy for a total item count using all twelve classes was 84.80%, but it increased to 90.20% when weighted by object area. The outcomes proved the feasibility of employing a succession of medium-resolution remote sensing images to generate comprehensive land cover maps over extensive perennial cropping regions. With an RF classifier, the authors of [3] created a real-time computer vision-based system to identify weeds in agricultural fields. The classification model was trained using the authors’ dataset, and then field data were used to verify its accuracy. They also created a fluid flow control system based on pulse width modulation, which uses the information provided by the vision system to regulate the spraying of an agrochemical. As a result, the authors proved the utility of their pesticide spraying method based on real-time vision.
In [34], a support vector machine (SVM) technique is used to detect weeds in chili field images. Examining how well the SVM classifier functions within a comprehensive weed-control strategy was the focus of their study. Five distinct types of weeds were depicted in the images they took of Bangladeshi chili crops. The authors used a global thresholding-based binarization algorithm to segment the images, separating the plants from the ground to extract features. Fourteen features were extracted from each image and sorted into color, shape, and moment invariants. Eventually, a support vector machine classifier was utilized to search for weeds. Their experiments determined that the SVM was 97% accurate over a set of 224 images. The authors of [27] presented a method for weed identification in sugar beet cultivation by utilizing a combination of numerous form elements to establish patterns that would be used to distinguish between sugar beets and weeds, which are visually quite similar. Images of sugar beet farms at Shiraz University served as the basis for this study. These images were altered using the MATLAB toolbox. Shape factors, moment invariants, and Fourier descriptors were among the properties of geometric space that the authors investigated to establish a distinction between weeds and sugar beets. Next, the authors utilized KNN and SVM classifiers, whose combined accuracy was 92.92% and 95%, respectively.
A color-index-based histogram is utilized to distinguish between weed, soybean, and soil classes, and a monochrome image is produced, as described in [28]. After scaling the image to a range of 0–255, greyscale images were obtained by creating and normalizing image histograms, which were then utilized for training BPNN and SVM classifiers. This study set out to find an alternate feature vector that will guarantee a high weed identification rate while also being computationally straightforward. In total, this method yielded accuracies of 96.60% for BPNN and 95.08% for SVM. The authors presented an automated weed identification system in [31] that could identify weeds at different developmental stages. In this case, sensors mounted on an unmanned aerial vehicle (UAV) were used to acquire color, multispectral, and thermal imagery. Using color images as the ground truth, researchers manually drew bounding boxes around plant bulbs and labeled them by hand. Next, they turned the gathered images into normalized difference vegetation index (NDVI) images using image processing techniques. At last, they used machine learning techniques to sort the weeds from the useful plants.
Images were obtained from a plant laboratory in Belgium, and the authors of [5] studied how well a hyperspectral snapshot mosaic camera worked at identifying weeds and maize. The calibration formula reflectance was obtained after these raw images were processed for the band features. One hundred eighty-five features were discovered across reflectance, NDVI, and RVI in the VB and NIR spectrums. To further streamline the process, the authors turned to a principal component analysis-based feature reduction technique. This data was then fed into feature selection algorithms, which were used to isolate relevant features. In the end, an RF classifier was employed to distinguish between weeds and crops. Accuracy for identifying various weeds was up to 81% overall. At an early stage in the development of herbaceous crops, the authors of [30] proposed an automated, RF-based image processing method for weed detection. This method combines digital surface models (DSMs) with orthomosaic methods using images captured by unmanned aerial vehicles (UAVs). After that, an RF classifier was utilized to differentiate between weeds and crops/soil, with results of 87.90% for sunflower fields and 84% for cotton fields, respectively. Obtaining radiometrically calibrated multispectral imaging, segmenting images, and employing a machine learning model are the essential components of a straightforward methodology presented in [24] for monitoring emerging and submerged invasive water soldiers. The eBee mapping drone was used to get the imagery. Pix4Dmapper Pro 3.0 was used to create the orthomosaic from the multispectral images.
The authors of [4] presented a method that uses UAVs to precisely predict when avocado plants are at particular stages of development. They shot the multispectral images with a Parrot Sequoia camera. After separating the digital terrain model from the digital surface model, a canopy height model was utilized to determine the height of the trees. Then, they used orthomosaic at-surface reflectance images and a variety of vegetation indices depending on the brightness of the plants in the red edge and NIR bands. The final step was implementing an RF method, which ended up being 96% accurate. UAV images from sunflower and maize fields were utilized in a weed mapping strategy proposed for precision agriculture in [33]. Object-based image analysis (OBIA) with a support vector machine (SVM) method linked with feature selection approaches was utilized to solve the spectral similarity problem for crop and weed pixels in the early growth stage. Spain’s private farms, La Monclova and El-Mazorcal, had images of sunflower and corn fields captured by the UAV. After that, the images were mosaicked with the help of the Agisoft Photoscan program, and then the items in the subsample were labeled using unsupervised feature selection approaches. At the same time, the automatic labeling was done under human oversight. These items were categorized as color histograms and data features based on remote-sensing measurements (first-order statistics, textures, etc.). The results showed that this SVM-based method had an overall accuracy of about 95.50%.

3. Materials and Methods

In this section, the dataset employed in this study is presented along with the key machine learning techniques, such as baseline classification models and ensemble approaches. In addition, the basics of grey wolf and sine cosine optimization methods forming the basis of the proposed optimization algorithm are presented in this section.

3.1. Data Collection

Field crops can be captured using sensors and UAVs equipped with cameras. In this work, the wheat crop images are captured using an autonomous sprayer drone, and the dataset is freely available on Kaggle [35]. Sample images in this dataset are shown in Figure 1. The collection dataset consists of 1176 wheat images and 4851 weed images in the training set. The testing set is composed of 130 wheat images and 540 weed images.

3.2. Pre-Trained AlexNet

Convolutional neural networks (CNNs) are a subset of multi-layer neural networks that extract information from images by analyzing their pixels [36]. Convolution, pooling, and fully linked layers are conventional CNN’s three fundamental building blocks. Convolution layers do the bulk of a CNN’s computations and are the most important building blocks. In other words, it filters the input using a convolutional filter and sends the result to the following layer. The input is filtered by the applied filter, which also serves as a feature identifier, yielding a feature map. The pooling layer’s job is to lower the space needed for the spatial representation and the computations that follow each successive convolution. Each sliced input is pooled in the pooling layer, lowering the computational burden of the subsequent convolution layer. Extraction and reduction of features from input images is achieved by applying convolution and pooling layers. When the fully linked layer is used, an amount of output proportional to the number of classes is produced. The layers that make up a CNN architecture are layered versions of each other. Despite some subtle differences, all CNNs are built on the same basic structure. In this work, the AlexNet pre-trained architecture is employed to extract useful features for classifying wheat and weed images.

3.3. Grey Wolf Optimizer

Grey wolf optimizer (GWO) motions are based on those of genuine wolves while they are on the prowl or hunting. Wolves tend to live in packs of varied sizes. A pack of wolves has a minimum of five members and a maximum of twelve members. There are four distinct varieties of wolves, each with a specific function within the pack. These are known as alpha, beta, omega, and delta [37]. Alpha-type wolves often make decisions on when and where to go for a stroll, hunt, and sleep with the assistance of beta-type wolves in the pack. It is generally accepted that alpha wolves are dominant wolves, with beta wolves serving as their subordinates. There are few better candidates to take over for the alpha wolf when they die. When alphas make judgments, the betas are there to support them and provide feedback to the alphas so they may make better decisions in the future; when it comes to the wolves of types alpha and beta, the delta wolves are typically subservient to the omegas. Delta wolves are divided into five groups: caretakers, hunters, elders, and scouts. In the group, each category has a distinct purpose. As the group’s “scapegoats”, the omega-type wolves had to submit to all the other wolves in the pack.
The grey wolf optimizer uses alpha, beta, and delta agents to lead the search for the optimum solution. In contrast, omega agents follow these three agents in the quest for the best solution. The alpha solution is considered the best-fitting solution in the grey wolf optimizer. On the other hand, the solutions of type beta and delta signify the second and third most suitable solutions.
Mathematically, the first, second, and third fittest solutions are denoted by ( P α ) , ( P β ) , and ( P δ ) , respectively, whereas ( P ω ) refers to all other solutions. The update process of the GWO algorithm is depicted in Figure 2. In this figure, the gamma wolves and other hunters are guided by the alpha, beta, and delta wolves, to efficiently manage the hunting process. The position updating is performed as follows.
P ( t + 1 ) = P s ( t ) A . | C . P s ( t ) P ( t ) |
where P is the wolf’s current location and t is the number of iterations the search algorithm has gone through. The prey’s location is denoted by P s ( t ) , and the coefficient vectors A and C are defined as follows.
A = 2 a . r 1 a
C = 2 r 2
There are two sets of random values for the vectors r 1 and r 2 , and the values of a are chosen from the range [ 0 , 2 ] in descending order. The updated values of the vector a govern the balance between the exploitation and exploration operations [37]. The following formula calculates the most recent change to this vector.
a = 2 t . 2 M t
where M t is the number of possible iterations. These positions are utilized to lead the other solutions, given by the symbol P ω , to move in the direction of the prey, as seen in the search process in Figure 2. The three best-fitting solutions are P α , P β , and P δ . The process of updating the positions of the wolves is described using the following equations by substitution of P s ( t ) in Equation (1) by P α , P β , and P δ .
D α = | C 1 . P α P ( t ) | , P 1 = P α A 1 . D α D β = | C 2 . P β P ( t ) | , P 2 = P β A 2 . D β D δ = | C 3 . P δ P ( t ) | , P 3 = P δ A 3 . D δ
The calculations of A 1 A 3 and C 1 C 3 are performed by Equations (2) and (3), respectively. The population’s new position is calculated as follows.
P ( t + 1 ) = P 1 + P 2 + P 3 3

3.4. Sine Cosine Algorithm

In [38], the sine cosine algorithm (SCA) was presented for the first time. The sine cosine oscillation function plays a crucial role in identifying the best possible solution locations, as shown in Figure 3. A set of random variables are used to represent the steps of the SCA’s operation [39,40].
  • The movement location.
  • The motion direction.
  • Swapping between the sine and cosine components.
  • Emphasizing/de-emphasizing the destination effect.
The update process of the candidate solutions is performed using the following equation.
S ( t + 1 ) = S ( t ) + r 1 . s i n ( r 2 ) . | r 3 P ( t ) S ( t ) | r 4 < 0.5 S ( t ) + r 1 . c o s ( r 2 ) . | r 3 P ( t ) S ( t ) | r 4 0.5
where t is the iteration number, the positions of the current and previous solutions at iterations t + 1 and t are denoted by S ( t + 1 ) , and S ( t ) , respectively. The position of the best solution is referred to as P . The values of [ 0 1 ] are allocated to the random variables r 2 , r 3 , and r 4 . The equation shows, for instance, that the positions of the optimal solutions affect the location of the current solution, making it simpler to reach the optimal solution. The following equation expresses the dynamic change in the value of r 1 .
r 1 = a a × t t m a x
where a is a constant, t and t m a x represent the current and maximum iterations, respectively.
Due to its reliance on a single optimal solution to guide the other solutions, the SCA algorithm is more robust than many other meta-heuristic algorithms presented in the literature [39,40]. The convergence speed and memory usage of this approach are relatively low when compared to other algorithms. However, as the number of locally optimal solutions increases, the algorithm’s performance degrades. To avoid being stuck in a local optimum, the proposed new algorithm incorporates the SCA optimizer and the GWO algorithm, taking advantage of their rapid convergence rates and memory efficiency and ensuring a balanced set of exploration and exploitation activities.

3.5. Baseline Machine Learning Models

This paper employs three baseline machine learning models to form the proposed ensemble voting approach. These base models are neural networks, k-nearest neighbors, and support vector machines. In this section, the basics of these models are presented briefly. On the other hand, ensemble methods cover two main types of ensemble methods: bagging classifier with a random forest as a type of averaging technique and Adaboost with a voting ensemble as a type of boosting technique. An introduction to these types of ensemble models is also presented in this section.

3.5.1. Neural Networks (NN)

Two or more layers of neurons and connections in the neural network structure allow it to learn a non-linear decision boundary. The term “processing elements” refers to what these neurons are often known as (PEs). The PEs use special training algorithms (such as ADAM and SGD) to try to mimic the operation of the human nervous system [42]. Input and output data can be separated by a “hidden layer”, a layer between the two that is not visible to the user. The calculation of the node output value weighted total is as follows:
S j = i = 1 n w i j I i + β j
in which I i is the input variable i, and w i j represents the hidden layer connection weight between I i and neuron j its β j , the bias. The sigmoid activation function may be used to define the node j output as follows:
f j ( S j ) = 1 1 + e x p S j
The value of f j ( S j ) is used to define the network output using the previously hidden layer neurons as:
y k = j = 1 m w j k f j ( S j ) + β k
The weights between neurons in the hidden layer and the output node are represented by w j k and β k , respectively.

3.5.2. K-Nearest Neighbors (KNN)

The K-nearest-neighbors (KNN) method is a non-parametric supervised classification technique that is both straightforward and useful in many contexts. Among classifiers used for pattern recognition, the KNN classifier is recommended due to its simple implementation, high accuracy, and speed of results [25]. It has various applications, including pattern recognition, machine learning, text classification, data mining, and object recognition. The KNN method employs a technique known as “classification by analogy”, wherein an unknown data item is compared to its neighbors in the training set. The Euclidean distance is the standard for comparing two samples’ degrees of similarity. Attributes with broader ranges are not given more weight than attributes with lower ranges by normalizing their attribute values. Using KNN, the most common category is used to categorize an unknown pattern. The following Euclidean distance equation is used to measure the distance between known/unknown data to determine the best category of the unknown label.
To classify dataset samples using the KNN approach, the nearest samples are considered to determine the final decision [43]. This approach depends mainly on the value of K, which represents the number of neighbors considered in classifying the dataset samples in terms of the following Euclidean distance.
D ( x t r a i n , x t e s t ) = i = 1 k ( x t r a i n x t e s t ) 2
This technique is used in conjunction with the NN in the proposed voting ensemble classifier for boosting the classification accuracy of wheat and weed images.

3.5.3. Support Vector Machine (SVM)

Support vector machine (SVM) is one of the effective machine learning models that can achieve promising performance when combined with deep networks and other machine learning models [44]. The basic formula of SVM is presented in the following.
f ( a ) = w . a + d
where a is the input variable, w is the weight vector, and d is the model’s error value. The discrepancy between anticipated and actual values can be reduced using SVM. According to the error indicator, SVM predicts the output label using an error reduction strategy based on the following optimization model.
M i n i m i z e : 1 2 | | w | | 2 + c i = 1 k ( c i c i + )
S u b j e c t ( t o ) : ( w x i + d ) b i < ϵ + c i + ,
b i ( w i a i + d ) ( ϵ + ϵ )
There are data violations whose varied values are larger than ϵ , the acceptable range with observable values, which are denoted by the coefficient of punishment C, the weight of the variables, the input variable, and the target observation ( w i ) , a i and b i . The values of the variables in Equations (15) and (16) are estimated to be used in Equation (14). It is possible to use a kernel function in SVM to describe the high-dimensional feature space of the input data points. The kernels are equipped to deal with a wide range of problems. Sigmoid, linear, polynomial, and radial basis functions (RBF) are among the four well-known SVM kernels employed. Because the RBF kernel has been shown to be capable of generalizing well to varied datasets, it was utilized in this investigation. As a result, Equation (13) may be interpreted as follows:
f ( a ) = w . H ( a , a i ) + d
H ( a , a i ) = e x p a a i 2 γ 2
where H ( a , a i ) is the kernel function and γ is the parameter of this function. Unknown values of SVM parameters such as C and ϵ are used as decision variables. The optimization procedure must thus include them.

3.5.4. Ensemble Models

Because of the reduced variance, the ensemble approaches aim to combine the outputs of machine learning (ML) classifiers. Several classifiers are built independently, and their results are then averaged (e.g., bagging classifier, random forest, and voting techniques) (soft and hard). Overfitting is less of an issue with these methods. One of the most often used and effective ensemble techniques for classification and regression is random choice forests (RF). Compared to single classifiers, ensemble models have attracted much attention because of their accuracy, and noise tolerance [45]. The average ensemble classifier results from the output predictions using the following formula.
f ^ = 1 B b = 1 B f b ( x )
Using a set of weak classifiers, the boosting approach of ensemble models creates a robust classifier. If you want to forecast unexpected observations accurately, this technique uses a set of classifier weights and a training data case for each iteration. Any machine learning approach that takes weights on the training set can be used as a base estimator. Various classifiers are trained on randomly generated training sets to generate the final result. The test sample is classified by combining the outputs of all models using uniform averaging or voting procedures over class labels by all classifiers in the ensemble. Because of the randomization in its structural approach, this methodology may be utilized to reduce variance and subsequently be used to form an ensemble. Machine learning estimators are combined, and a majority vote (i.e., the output of each estimator) is termed hard voting in this approach. The class label is returned as the argmax of the sum of the predicted probabilities via soft voting or average predicted probabilities on the other hand [46]. For each classifier, the anticipated class probabilities are gathered. An average of the weights assigned to each classifier is then calculated. The class label determines the final class label (i.e., the highest average probability). ML classifiers of equivalent performance can use this strategy to counteract one other’s flaws.

4. The Proposed Methodology

In this section, the proposed methodology is explained. The methodology starts with extracting the features of the input images using the deep network through transfer learning. The extracted features are then processed to select the most relevant features that boost the classification accuracy. The selected features are then used to learn three base models: NN, KNN, and SVM. These models are employed in a voting classifier optimized using the proposed optimization algorithm. The steps of the proposed methodology are depicted in Figure 4. The next section discusses the main steps of the proposed methodology.

4.1. Transfer Learning

In deep learning applications, the process of transfer learning is widely used [47], which is beneficial in the case of a limited dataset. To learn a new classification task, a pre-trained network is considered, such as AlexNet. In this work, we adopted AlexNet, which is trained using a large dataset, ImageNet. In the transfer learning process, the three connected layers of the AlexNet are replaced with the proposed voting classifier. The transfer learning process employed in this work is depicted in Figure 5.

4.2. Feature Extraction

Processing raw data to extract additional variables that aid machine learning algorithms is the focus of the feature extraction process. This work adopts AlexNet [48] for feature extraction. Figure 4 shows how AlexNet enlarges the input image to a fixed size of 227 × 227 × 3, using a 256-layer convolution filter with a window shape of 11 × 11, a 256-layer filter with a window shape of 5 × 5, and then 384, 384, and 256-layer convolution filters with a window size of 3 × 3 for the remaining three layers of the process. After the first, second, and final convolutional layers, the network has a maximum number of 3 × 3 pooling layers with a stride of 2. There are two fully connected layers with 4096 neuron outputs following the fifth convolutional layer in addition to these five layers. Afterward, there is a single completely linked output layer at the end of the network, which originally had 1000 output classes. In the end, Dropout, ReLU, and preprocessing are critical if you want top results in computer vision applications. This work replaces the last three layers with the proposed optimized voting ensemble model, which classifies only two classes (wheat and weed).

4.3. The Proposed Optimization Algorithm

The optimization of the proposed voting ensemble classifier is performed in terms of a new optimization algorithm based on the SCA and GWO optimization algorithms. The proposed optimization algorithm is referred to as the adaptive dynamic sine cosine fitness grey wolf optimization (ADSCFGWO) algorithm, with the steps listed in Algorithm 1.
Algorithm 1: The proposed ADSCFGWO algorithm.
1:
Initialize population P i ( i = 1 , 2 , , n ) with size n, maximum iterations I t e r M a x , fitness function H n , a , A 1 , A 2 , A 3 , C 1 , C 2 , r 1 , r 2 , r 3 , r 4
2:
procedure DYNAMICSEARCH( H n )
3:
    if (Fitness H n did not change for three iterations) then
4:
       Increase the exploration group solutions
5:
       Decrease the exploitation group solutions
6:
    end if
7:
end procedure
8:
Calculate  H n fitness for each P i
9:
Find the first three best solutions denoted by P α , P β , P δ
10:
Set t = 1
11:
while  t I t e r M a x  do
12:
    Update  r 1 by r 1 = a 1 t I t e r M a x
13:
    for ( i = 1 : i < n 1 + 1 ) do
14:
       DynamicSearch( H n )
15:
       Update  H α = H α H α + H β + H δ
16:
        H β = H β H α + H β + H δ
17:
        H δ = H δ H α + H β + H δ
18:
       Calculate  M = | C 1 . ( H α P α + H β P β + H δ P δ ) P ( t ) |
19:
       Calculate  V 1 = P α A 1 . M
20:
       Calculate  V 2 = P β A 2 . M
21:
       Calculate  V 3 = P δ A 3 . M
22:
       Update positions as P ( t + 1 ) = V 1 + V 2 + V 3 3
23:
       if ( r 4 < 0.5 ) then
24:
            P ( t + 1 ) = P ( t ) + r 1 × sin ( r 2 ) × | r 3 P α P ( t ) |
25:
       end if
26:
    end for
27:
    for ( i = 1 : i < n 2 + 1 ) do
28:
       DynamicSearch( H n )
29:
        H α = H α H α + H β + H δ
30:
        H β = H β H α + H β + H δ
31:
        H δ = H δ H α + H β + H δ
32:
       Calculate  M = | C 2 . ( H α P α + H β P β + H δ P δ ) P ( t ) |
33:
       Calculate  V 1 = P α A 1 . M
34:
       Calculate  V 2 = P β A 2 . M
35:
       Calculate  V 3 = P δ A 3 . M
36:
       Update positions as P ( t + 1 ) = V 1 + V 2 + V 3 3
37:
       if ( r 4 0.5 ) then
38:
            P ( t + 1 ) = P ( t ) + r 1 × cos ( r 2 ) × | r 3 P α P ( t ) |
39:
       end if
40:
    end for
41:
    Update  H n , A 1 , A 2 , A 3 , C 1 , C 2 , r 1 , r 2 , r 3 , r 4 , P α , P β , P δ , t
42:
    Find best individual P *
43:
end while
44:
Return  P *

4.3.1. Exploration/Exploitation Balance

The proposed ADSCFGWO algorithm automatically strikes the right balance between exploration and exploitation by dividing the population into smaller groups. Exploration and exploitation groups make up 70% of the population in this algorithm, which divides the population into two categories. An early exploration group with a high number of participants helps to identify new and intriguing search regions. Overall fitness grows, but the number of exploration group members drops from 70% to 30% due to more exploitative people gaining fitness values. If a better solution cannot be identified, an elitist technique maintains convergence by keeping the process leader in place in subsequent populations. ADSCFGWO can expand the size of the exploration group at any point if the fitness of the group’s leader has not increased sufficiently throughout three iterations.

4.3.2. Fitness Function

The following equation is used to assess the quality of the solutions discovered by the optimization algorithms.
H n = α E r r o r ( P ) + β | S | | A |
where P stands for the model’s variables. It can be noted that a certain trait is important to the population by looking for the values of α [0 to 1] and β = 1 α . The total number of features is denoted by | S | .

4.4. Feature Selection

Features that meet particular criteria, such as originality, consistency, and meaningfulness, are selected and identified throughout the feature selection process. Two binary values (0 and 1) are utilized in the feature selection procedure to limit the search space. Therefore, continuous values-based optimizers require an update to deal with this problem effectively. This is the essential phase in feature engineering since it allows optimizers to choose the most optimal features for maximum performance. There are several ways to think about selecting features, such as a binary vector, in which each feature has an equal chance of being included in the solution or not [49]. Random populations of vectors with random features can be utilized as a starting point for meta-heuristic algorithms. This is followed by an iterative process of exploring and exploiting to identify the best collection of features [50]. To determine whether a feature is relevant, the search space is confined to binary values (0 and 1) alone. The proposed binary ADSCFGWO (bADSCFGWO) method is proposed to transform the continuous values from the continuous ADSCFGWO algorithm into binary {0, 1} values to fit the feature selection procedure. The S i g m o i d function used to convert the continuous solution to binary values is represented by the following equation, and the steps of the proposed binary optimization algorithm are listed in Algorithm 2.    
Algorithm 2: The proposed bADSCFGWO feature selection algorithm.
1:
Initialize the population, and configuration parameters
2:
Convert the solution to binary {0, 1}.
3:
Select the best solutions using the objective function
4:
while t I t e r M a x do
5:
    Run the proposed ADSCFGWO algorithm
6:
    Convert solutions to binary using Equation (21)
7:
    Measure fitness function
8:
    Update the algorithm parameters
9:
end while
10:
Return P *
B ( t + 1 ) = 1 if S i g m o i d ( m ) 0.5 0 o t h e r w i s e , S i g m o i d ( m ) = 1 1 + e 10 ( m 0.5 )
where at iteration t, m refers to the best answer.

5. Experimental Results

To evaluate the proposed approach of weed detection, a set of experiments were conducted to assess the performance of the process of the proposed approach. The assessment included the steps of feature selection, classification methods, and the proposed optimized voting classifiers approach. The coming sections present the details of the achievements.

5.1. Configuration Parameters

The first set of experiments was conducted to determine the best collection of values assigned to the configuration parameters. Table 2 presents the set of values of the parameters of the optimization of the feature selection process. In addition, the configuration parameters of the grey wolf and other optimization algorithms are presented in Table 3. The values of these parameters are employed in the proposed optimization algorithm and the algorithms used in the comparison experiments.

5.2. Evaluation Metrics

The metrics used to assess the feature selection approach are presented in Table 4. These criteria include the average fitness size, average error, standard deviation, best fitness, worst fitness, and mean error. In their criteria, M refers to the number of runs of the optimizer, j refers to the run number, g j * is the best solution at run number j, and the size of the best solution vector is referred to as s i z e ( g j * ) , the number of points in the test set is denoted by N. The output class label is C i for the data point i corresponding to the label L i . D denotes the total number of features.
On the other hand, the metrics used to assess the proposed voting classifier are presented in Table 5. These metrics include F1-score, specificity, accuracy, sensitivity, Nvalue, and Pvalue. The true positive, true negative, false positive, and false negative measures used in these metrics are denoted by T P , T N , F P , and F N , respectively.

5.3. Feature Extraction Results

Deep learning is one of the main approaches to extracting effective features from images. In this work, to select the deep network that selects the best features from the given images, an experiment is conducted to study the effectiveness of the features extracted from three deep networks, namely, VGGNet, ResNet-50, and AlexNet. The results are recorded and presented in Table 6. As presented in this table, the best results are achieved using AlexNet, and thus this network is adopted for the rest of the conducted experiments.

5.4. Evaluating the Proposed Feature Selection Method

The feature selection applied to the weed features is performed using the proposed binary ADSCFGWO. The achieved results are compared with other state-of-the-art binary optimization techniques; namely, grey wolf optimizer (GWO) [51], hybrid GWO and PSO (bGWO_PSO) [52], particle swarm optimization (PSO) [53], whale optimization algorithm (WOA) [54], firefly algorithm (FA) [55], and genetic algorithm (GA) [56]. The evaluation results are presented in Table 7. As presented in the table, the proposed binary ADSCFGWO algorithm achieved the best average error (0.69504) compared to the other optimization algorithms. In addition, average select size, mean fitness, worst fitness, and standard deviation are superior for the proposed algorithm compared to the other algorithms.

5.5. Evaluating the Proposed Optimized Voting Classifier

Three baseline models have been experimented with and evaluated separately. These models are KNN, SVM, and NN. The recorded results are presented in Table 8. In this table, the accuracy achieved by KNN, SVM, and NN is 89.1%, 92.1%, and 93.5%, respectively. From these results, it can be noted that the NN baseline model achieves the best performance.
The proposed ADSCFGWO algorithm is used to optimize the parameters of a voting ensemble model composed of the three baseline models. To prove the proposed approach’s superiority, the results are compared to those of four other optimization algorithms, namely, WOA, GWO, GA, and PSO. Table 9 presents the recorded results. In this table, it can be noted that the results achieved by the proposed optimized voting ensemble are better than those achieved by optimizing the voting ensemble using other optimization methods.
On the other hand, a set of experiments is conducted to analyze the proposed approach’s performance statistically. Table 10 presents the statistical analysis results. This table shows that based on 20 random samples, the mean accuracy is 97.74% and the standard deviation is relatively tiny (0.0004894), indicating the proposed approach’s robustness. When these results are compared to those of the other optimization algorithms, the superiority of the proposed approach is obvious.
The significance and stability of the proposed approach are studied in terms of the analysis of variance (ANOVA) and Wilcoxon signed-rank tests. The results are shown in Table 11 and Table 12. The measured p-value of the ANOVA and Wilcoxon tests is ( p < 0.0001 ), which indicates the significance of the proposed approach.
A visual representation of the results achieved by the proposed approach is shown in Figure 6. This figure shows the residual plot with residual error in the range of (−0.015 to 0.010). The homoscedasticity and QQ plots show a robust prediction of the class labels. On the other hand, the heatmap indicates a promising performance using the proposed ADSCFGWO algorithm, which is better than the other optimization algorithms.
The receiver operating characteristic (ROC) plot depicted in Figure 7 shows robust detection results. In addition, this figure’s accuracy and histogram plots show a promising performance that outperforms the results of the other optimization algorithms.

5.6. Sensitivity Analysis of the Proposed Approach

One-at-a-time (OAT) sensitivity analysis was used to study the sensitivity analysis. Regarding sensitivity analysis, OAT is one of the most straightforward methods. To test the algorithm’s performance, one parameter at a time is changed while the other parameters remain the same. As the values of various factors were varied, the convergence time and ADSCFGWO’s fitness values changed accordingly (as presented in Table 13, Table 14, Table 15 and Table 16). When evaluating each parameter, 20 values are selected in that parameter’s interval by multiplying the interval’s length by 5%. As a result, the algorithm ran ten times for each number; the results are shown in the table below. It took 100 runs of ADSCFGWO for each parameter.

5.6.1. Statistical Significance of the Results

The one-way analysis of variance (ANOVA) is performed to assess the significant difference between the proposed approach and other approaches. While modifying the settings of ADSCFGWO, two ANOVA tests are applied to both the convergence time and the fitness values. Table 17 shows the ANOVA test results for ADSCFGWO’s convergence time and lowest fitness. Table 18 shows that p-values are less than (0.05) and F is larger than the F-critical level. Because of this, there is a statistically significant difference between the average of each parameter’s five groups of convergence time. When each parameter’s value is changed, a statistically significant difference can be seen between the means of all five minimal fitness groups. ANOVA does not tell which groups have statistical significance. As a result, a post hoc analysis is carried out between each pair of groups. A significance threshold of (0.05) was used for this purpose in a one-tailed t-test. Table 19 tested the algorithm’s parameters using the t-test based on the convergence time and minimum fitness of ADSCFGWO. There is a statistically significant difference between groups, with p-values less than (0.05) according to the table. As for convergence time, there is a t-test between the exploration percentage and mutation rate that is statistically significant (0.05). This proposes that no statistically significant difference exists between their impacts on the time of convergence. The number of iterations or the mutation rate does not affect the minimal fitness. A visual representation of the study of the sensitivity of the algorithm parameters is represented by the plots shown in Figure 8. In this figure, the residual plot and homoscedasticity show the stability of the parameters. In addition, the QQ and heatmap plots show the robustness of the optimized parameters.
The histogram depicted in Figure 9 shows the convergence time of the parameters of the proposed algorithm. In this figure, it can be noted that some parameters converge faster than others. For example, r 3 , r 2 , A 2 , and C 1 converge faster than the other parameters. However, all the parameters converge in 12.4 s. In addition, the histogram of the convergence time of the proposed ADSCFGWO is depicted in Figure 10.
A study of the sensitivity of the fitness of the proposed approach is conducted, and the results are recorded in Table 20, Table 21 and Table 22. These tables represent the ANOVA test, the Wilcoxon test, and the statistical analysis of the achieved results. It can be noted from these tables that the parameters of the proposed algorithm as the p-value < 0.0001.
The fitness of the parameters of the proposed approach is analyzed, and the results are presented in Table 20, Table 21 and Table 22 in terms of the statistical analysis using Wilcoxon and ANOVA tests. These results show the effectiveness of the analyzed parameters in solving the optimization problem.
More investigation of the effectiveness of the parameters of the proposed approach is performed using the set of plots depicted in Figure 11, Figure 12 and Figure 13. These figures show the significance of the parameters in the optimization problem and the convergence of the fitness.

5.6.2. Discussion and Ranking of Parameters

The parameters of the proposed ADSCFGWO algorithm can be ordered according to their effect on the fitness values as follows: C 2 , A 1 , r 4 , r 1 , C 1 , A 3 , A 2 , r 2 , and r 3 . It is also possible to rank the following variables in the order of their impact on the convergence time: r 1 , A 2 , C 2 , r 3 , r 4 , A 1 , C 1 , and r 2 . The ADSCFGWO algorithm’s convergence time is influenced by r 2 . The value of r 2 has the least impact on the algorithm’s convergence for all of these reasons. The ADSCFGWO algorithm’s convergence time is strongly influenced by r 1 , r 2 , r 3 , and A 2 values. The ADSCFGWO algorithm has a convergence time sensitive to exploration percentages larger than 25%. In terms of fitness, C 2 and A 1 significantly impact the algorithm’s performance.

5.7. Discussion

A set of experimental setups is used to evaluate the effectiveness of the proposed methodology in identifying wheat/weed images. Firstly, positive results indicate the effectiveness of the features derived from the AlexNet architecture through transfer learning. The features retrieved from AlexNet are then used in a feature selection scenario. In the second scenario, the proposed ADSCFGWO algorithm proves both stable and dependable in its quest to identify the best possible collection of features in a reasonable period. In addition, the Wilcoxon rank-sum test highlights the relevance of the proposed ADSCFGWO algorithm by demonstrating its statistical significance. On the other hand, other experiments are conducted to demonstrate that the proposed optimized voting classifier outperforms the competing methods when classifying the input crop image, with a mean accuracy of (97.75%). A sensitivity analysis is carried out to ensure the proposed method is reliable. Testing and results show that the proposed technique is highly effective in classifying wheat/weed images.

6. Conclusions

This paper proposes a new approach to classify wheat and weed in drone-captured images based on metaheuristic optimization and machine learning. The proposed approach is based on a new optimized voting classifier that could efficiently classify the features extracted using AlexNet. To boost the classification accuracy, the extracted features are optimized to select the significant features based on a new binary optimization algorithm. The optimization of the voting classifier and the binary optimization algorithm developed for feature selection are based on the GWO and SCA optimization algorithms in a new hybrid optimization algorithm referred to as the ADSCFGWO algorithm. The proposed voting classifier comprises three machine-learning models: NN, SVM, and KNN. These classifiers’ contribution to the final results is optimized using the proposed optimization algorithm. The proposed approach’s efficiency was evaluated using various metrics, including accuracy, precision, recall, false positive rate, and kappa coefficient. In addition, the ANOVA and Wilcoxon signed-rank tests are used to assess the reliability and validity of the proposed methodology. Moreover, a sensitivity analysis is carried out to investigate the impact of varying parameters of the proposed approach on the observed outcomes. The proposed methodology was superior to existing optimization strategies in a series of experiments with a detection accuracy of 97.70%, an F-score of 98.60%, a specificity of 95.20%, and a sensitivity of 98.40%. From the statistical analysis, the ANOVA and Wilcoxon signed-rank tests showed the value of p as (p < 0.005), indicating the proposed approach’s statistical difference.

Author Contributions

Conceptualization, E.-S.M.E.-K. and N.K.; methodology, S.M.; software, T.M.; validation, M.A., F.K.K. and H.K.A.; formal analysis, A.A.A.; investigation, M.M.E.; resources, T.H.; data curation, A.I.; writing—original draft preparation, A.A.A.; writing—review and editing, A.A.A.; visualization, D.S.K.; supervision, D.S.K.; project administration, E.-S.M.E.-K.; funding acquisition, H.K.A. All authors have read and agreed to the published version of the manuscript.

Funding

Princess Nourah bint Abdulrahman University Researchers Supporting Project number (PNURSP2022R300), Princess Nourah bint Abdulrahman University, Riyadh, Saudi Arabia.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The data is publicly available at: https://www.kaggle.com/datasets/gavinarmstrong/open-sprayer-images, accessed on 1 November 2022.

Acknowledgments

Princess Nourah bint Abdulrahman University Researchers Supporting Project number (PNURSP2022R300), Princess Nourah bint Abdulrahman University, Riyadh, Saudi Arabia.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Singh, A.; Ganapathysubramanian, B.; Singh, A.K.; Sarkar, S. Machine Learning for High-Throughput Stress Phenotyping in Plants. Trends Plant Sci. 2016, 21, 110–124. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  2. Dadashzadeh, M.; Abbaspour-Gilandeh, Y.; Mesri-Gundoshmian, T.; Sabzi, S.; Hernández-Hernández, J.L.; Hernández-Hernández, M.; Arribas, J.I. Weed Classification for Site-Specific Weed Management Using an Automated Stereo Computer-Vision Machine-Learning System in Rice Fields. Plants 2020, 9, 559. [Google Scholar] [CrossRef]
  3. Alam, M.; Alam, M.S.; Roman, M.; Tufail, M.; Khan, M.U.; Khan, M.T. Real-Time Machine-Learning Based Crop/Weed Detection and Classification for Variable-Rate Spraying in Precision Agriculture. In Proceedings of the 2020 7th International Conference on Electrical and Electronics Engineering (ICEEE); IEEE: Antalya, Turkey, 2020; pp. 273–280. [Google Scholar] [CrossRef]
  4. Tu, Y.H.; Johansen, K.; Phinn, S.; Robson, A. Measuring Canopy Structure and Condition Using Multi-Spectral UAS Imagery in a Horticultural Environment. Remote Sensing 2019, 11, 269. [Google Scholar] [CrossRef] [Green Version]
  5. Gao, J.; Nuyttens, D.; Lootens, P.; He, Y.; Pieters, J.G. Recognising weeds in a maize crop using a random forest machine-learning algorithm and near-infrared snapshot mosaic hyperspectral imagery. Biosyst. Eng. 2018, 170, 39–50. [Google Scholar] [CrossRef]
  6. Myers, S.S.; Smith, M.R.; Guth, S.; Golden, C.D.; Vaitla, B.; Mueller, N.D.; Dangour, A.D.; Huybers, P. Climate Change and Global Food Systems: Potential Impacts on Food Security and Undernutrition. Annu. Rev. Public Health 2017, 38, 259–277. [Google Scholar] [CrossRef] [PubMed]
  7. Aharon, S.; Peleg, Z.; Argaman, E.; Ben-David, R.; Lati, R.N. Image-Based High-Throughput Phenotyping of Cereals Early Vigor and Weed-Competitiveness Traits. Remote Sensing 2020, 12, 3877. [Google Scholar] [CrossRef]
  8. Herrmann, I.; Bdolach, E.; Montekyo, Y.; Rachmilevitch, S.; Townsend, P.A.; Karnieli, A. Assessment of maize yield and phenology by drone-mounted superspectral camera. Precis. Agric. 2020, 21, 51–76. [Google Scholar] [CrossRef]
  9. Juan-wei, Z. Review of Mechanical Weeding Technique in Field at Home and Abroad. J. Agric. Mech. Res. 2006, 10, 14–16. [Google Scholar]
  10. Barbosa, P.F.P. Voltammetric Techniques for Pesticides and Herbicides Detection- an Overview. Int. J. Electrochem. Sci. 2019, 14, 3418–3433. [Google Scholar] [CrossRef]
  11. Liakos, K.G.; Busato, P.; Moshou, D.; Pearson, S.; Bochtis, D.D. Machine Learning in Agriculture: A Review. Sensors 2018, 18, 2674. [Google Scholar] [CrossRef]
  12. Forero, M.G.; Herrera-Rivera, S.; Ávila-Navarro, J.; Franco, C.A.; Rasmussen, J.; Nielsen, J. Color Classification Methods for Perennial Weed Detection in Cereal Crops. In Proceedings of the CIARP, Madrid, Spain, 19–22 November 2018. [Google Scholar]
  13. Dyrmann, M.; Karstoft, H.; Midtiby, H.S. Plant species classification using deep convolutional neural network. Biosyst. Eng. 2016, 151, 72–80. [Google Scholar] [CrossRef]
  14. Milioto, A.; Lottes, P.; Stachniss, C. Real-Time Semantic Segmentation of Crop and Weed for Precision Agriculture Robots Leveraging Background Knowledge in CNNs. In Proceedings of the 2018 IEEE International Conference on Robotics and Automation (ICRA), Brisbane, Australia, 21–25 May 2018; pp. 2229–2235. [Google Scholar] [CrossRef] [Green Version]
  15. dos Santos Ferreira, A.; Freitas, D.M.; da Silva, G.G.; Pistori, H.; Folhes, M.T. Weed detection in soybean crops using ConvNets. Comput. Electron. Agric. 2017, 143, 314–324. [Google Scholar] [CrossRef]
  16. Ishak, A.J.; Hussain, A.; Mustafa, M.M. Weed image classification using Gabor wavelet and gradient field distribution. Comput. Electron. Agric. 2009, 66, 53–61. [Google Scholar] [CrossRef]
  17. OKAMOTO, H.; MURATA, T.; KATAOKA, T.; HATA, S.I. Plant classification for weed detection using hyperspectral imaging with wavelet analysis. Weed Biol. Manag. 2007, 7, 31–37. [Google Scholar] [CrossRef]
  18. Goel, P.; Prasher, S.; Patel, R.; Landry, J.; Bonnell, R.; Viau, A. Classification of hyperspectral data by decision trees and artificial neural networks to identify weed stress and nitrogen status of corn. Comput. Electron. Agric. 2003, 39, 67–93. [Google Scholar] [CrossRef]
  19. Tian, H.; Wang, T.; Liu, Y.; Qiao, X.; Li, Y. Computer vision technology in agricultural automation—A review. Inf. Process. Agric. 2020, 7, 1–19. [Google Scholar] [CrossRef]
  20. Wang, A.; Zhang, W.; Wei, X. A review on weed detection using ground-based machine vision and image processing techniques. Comput. Electron. Agric. 2019, 158, 226–240. [Google Scholar] [CrossRef]
  21. Herrmann, I.; Shapira, U.; Kinast, S.; Karnieli, A.; Bonfil, D.J. Ground-level hyperspectral imagery for detecting weeds in wheat fields. Precis. Agric. 2013, 14, 637–659. [Google Scholar] [CrossRef]
  22. Weis, M.; Gutjahr, C.; Rueda Ayala, V.; Gerhards, R.; Ritter, C.; Schölderle, F. Precision farming for weed management: Techniques. Gesunde Pflanz. 2008, 60, 171–181. [Google Scholar] [CrossRef]
  23. Abdelhamid, A.; Alotaibi, S. Optimized Two-Level Ensemble Model for Predicting the Parameters of Metamaterial Antenna. Comput. Mater. Contin. 2022, 73, 917–933. [Google Scholar] [CrossRef]
  24. Chabot, D.; Dillon, C.; Shemrock, A.; Weissflog, N.; Sager, E. An Object-Based Image Analysis Workflow for Monitoring Shallow-Water Aquatic Vegetation in Multispectral Drone Imagery. ISPRS Int. J. Geo Inf. 2018, 7, 294. [Google Scholar] [CrossRef] [Green Version]
  25. Brinkhoff, J.; Vardanega, J.; Robson, A.J. Land Cover Classification of Nine Perennial Crops Using Sentinel-1 and -2 Data. Remote Sensing 2019, 12, 96. [Google Scholar] [CrossRef] [Green Version]
  26. Zhang, S.; Guo, J.; Wang, Z. Combing K-means Clustering and Local Weighted Maximum Discriminant Projections for Weed Species Recognition. Front. Comput. Sci. 2019, 1, 4. [Google Scholar] [CrossRef]
  27. Bakhshipour, A.; Jafari, A. Evaluation of support vector machine and artificial neural networks in weed detection using shape features. Comput. Electron. Agric. 2018, 145, 153–160. [Google Scholar] [CrossRef]
  28. Abouzahir, S.; Sadik, M.; Sabir, E. Enhanced Approach for Weeds Species Detection Using Machine Vision. In Proceedings of the 2018 International Conference on Electronics, Control, Optimization and Computer Science (ICECOCS); IEEE: Kenitra, Morocco, 2018; pp. 1–6. [Google Scholar] [CrossRef]
  29. Kazmi, W.; Garcia-Ruiz, F.J.; Nielsen, J.; Rasmussen, J.; Jørgen Andersen, H. Detecting creeping thistle in sugar beet fields using vegetation indices. Comput. Electron. Agric. 2015, 112, 10–19. [Google Scholar] [CrossRef] [Green Version]
  30. Fernandez-Gallego, J.A.; Lootens, P.; Borra-Serrano, I.; Derycke, V.; Haesaert, G.; Roldán-Ruiz, I.; Araus, J.L.; Kefauver, S.C. Automatic wheat ear counting using machine learning based on RGB UAV imagery. Plant J. 2020, 103, 1603–1613. [Google Scholar] [CrossRef]
  31. Etienne, A.; Saraswat, D. Machine learning approaches to automate weed detection by UAV based sensors. In Proceedings of the Autonomous Air and Ground Sensing Systems for Agricultural Optimization and Phenotyping IV; Thomasson, J.A., McKee, M., Moorhead, R.J., Eds.; SPIE: Baltimore, ML, USA, 2019; p. 25. [Google Scholar] [CrossRef]
  32. Islam, N.; Rashid, M.M.; Wibowo, S.; Xu, C.Y.; Morshed, A.; Wasimi, S.A.; Moore, S.; Rahman, S.M. Early Weed Detection Using Image Processing and Machine Learning Techniques in an Australian Chilli Farm. Agriculture 2021, 11, 387. [Google Scholar] [CrossRef]
  33. Pérez-Ortiz, M.; Peña, J.M.; Gutiérrez, P.A.; Torres-Sánchez, J.; Hervás-Martínez, C.; López-Granados, F. Selecting patterns and features for between- and within- crop-row weed mapping using UAV-imagery. Expert Syst. Appl. 2016, 47, 85–94. [Google Scholar] [CrossRef] [Green Version]
  34. Ahmed, F.; Al-Mamun, H.A.; Bari, A.H.; Hossain, E.; Kwan, P. Classification of crops and weeds from digital images: A support vector machine approach. Crop. Prot. 2012, 40, 98–104. [Google Scholar] [CrossRef]
  35. Armstrong, G. Open Sprayer Images. 2018. Available online: https://www.kaggle.com/datasets/gavinarmstrong/open-sprayer-images (accessed on 1 November 2022).
  36. Ateeq, T.; Majeed, M.N.; Anwar, S.M.; Maqsood, M.; ur Rehman, Z.; Lee, J.W.; Muhammad, K.; Wang, S.; Baik, S.W.; Mehmood, I. Ensemble-classifiers-assisted detection of cerebral microbleeds in brain MRI. Comput. Electr. Eng. 2018, 69, 768–781. [Google Scholar] [CrossRef]
  37. Mirjalili, S.; Mirjalili, S.M.; Lewis, A. Grey Wolf Optimizer. Adv. Eng. Softw. 2014, 69, 46–61. [Google Scholar] [CrossRef] [Green Version]
  38. Mirjalili, S. SCA: A Sine Cosine Algorithm for solving optimization problems. Knowl. Based Syst. 2016, 96, 120–133. [Google Scholar] [CrossRef]
  39. Eid, M.M.; El-kenawy, E.S.M.; Ibrahim, A. A binary Sine Cosine-Modified Whale Optimization Algorithm for Feature Selection. In Proceedings of the National Computing Colleges Conference (NCCC), Taif, Saudi Arabia, 27–28 March 2021; pp. 1–6. [Google Scholar] [CrossRef]
  40. Abdelhamid, A.A.; El-Kenawy, E.S.M.; Khodadadi, N.; Mirjalili, S.; Khafaga, D.S.; Alharbi, A.H.; Ibrahim, A.; Eid, M.M.; Saber, M. Classification of Monkeypox Images Based on Transfer Learning and the Al-Biruni Earth Radius Optimization Algorithm. Mathematics 2022, 10, 3614. [Google Scholar] [CrossRef]
  41. Xian, H.; Yang, C.; Wang, H.; Yang, X. A Modified Sine Cosine Algorithm With Teacher Supervision Learning for Global Optimization. IEEE Access 2021, 9, 17744–17766. [Google Scholar] [CrossRef]
  42. El-Kenawy, E.S.M.; Mirjalili, S.; Ibrahim, A.; Alrahmawy, M.; El-Said, M.; Zaki, R.M.; Eid, M.M. Advanced Meta-Heuristics, Convolutional Neural Networks, and Feature Selectors for Efficient COVID-19 X-Ray Chest Image Classification. IEEE Access 2021, 9, 36019–36037. [Google Scholar] [CrossRef] [PubMed]
  43. El-Kenawy, E.S.M.; Eid, M.M.; Saber, M.; Ibrahim, A. MbGWO-SFS: Modified Binary Grey Wolf Optimizer Based on Stochastic Fractal Search for Feature Selection. IEEE Access 2020, 8, 107635–107649. [Google Scholar] [CrossRef]
  44. Shi, X.; Huang, Q.; Chang, J.; Wang, Y.; Lei, J.; Zhao, J. Optimal parameters of the SVM for temperature prediction. Proc. Int. Assoc. Hydrol. Sci. 2015, 368, 162–167. [Google Scholar] [CrossRef]
  45. El-Kenawy, E.S.M.; Ibrahim, A.; Mirjalili, S.; Eid, M.M.; Hussein, S.E. Novel Feature Selection and Voting Classifier Algorithms for COVID-19 Classification in CT Images. IEEE Access 2020, 8, 179317–179335. [Google Scholar] [CrossRef]
  46. Ibrahim, A.; Tharwat, A.; Gaber, T.; Hassanien, A.E. Optimized superpixel and AdaBoost classifier for human thermal face recognition. Signal, Image Video Process. 2018, 12, 711–719. [Google Scholar] [CrossRef]
  47. Maqsood, M.; Nazir, F.; Khan, U.; Aadil, F.; Jamal, H.; Mehmood, I.; Song, O.y. Transfer Learning Assisted Classification and Detection of Alzheimer’s Disease Stages Using 3D MRI Scans. Sensors 2019, 19, 2645. [Google Scholar] [CrossRef] [Green Version]
  48. Krizhevsky, A.; Sutskever, I.; Hinton, G.E. ImageNet Classification with Deep Convolutional Neural Networks. Commun. ACM 2017, 60, 84–90. [Google Scholar] [CrossRef] [Green Version]
  49. Al-Tashi, Q.; Abdul Kadir, S.J.; Rais, H.M.; Mirjalili, S.; Alhussian, H. Binary Optimization Using Hybrid Grey Wolf Optimization for Feature Selection. IEEE Access 2019, 7, 39496–39508. [Google Scholar] [CrossRef]
  50. Madadi, A.; Motlagh, M.M. Optimal Control of DC motor using Grey Wolf Optimizer Algorithm. Tech. J. Eng. Appl. Sci. 2014, 4, 373–379. [Google Scholar]
  51. El-kenawy, E.S.; Eid, M. Hybrid Gray Wolf and Particle Swarm Optimization for Feature Selection. Int. J. Innov. Comput. Inf. Control. IJICIC 2020, 16, 831–844. [Google Scholar] [CrossRef]
  52. Şenel, F.A.; Gökçe, F.; Yüksel, A.S.; Yigit, T. A novel hybrid PSO–GWO algorithm for optimization problems. Eng. Comput. 2019, 35, 1359–1373. [Google Scholar] [CrossRef]
  53. Bello, R.; Gomez, Y.; Nowe, A.; Garcia, M.M. Two-Step Particle Swarm Optimization to Solve the Feature Selection Problem. In Proceedings of the Seventh International Conference on Intelligent Systems Design and Applications (ISDA 2007), Rio de Janeiro, Brazil, 20–24 October 2007; pp. 691–696. [Google Scholar] [CrossRef]
  54. Mirjalili, S.; Lewis, A. The Whale Optimization Algorithm. Adv. Eng. Softw. 2016, 95, 51–67. [Google Scholar] [CrossRef]
  55. Fister, I.; Yang, X.S.; Fister, I.; Brest, J. Memetic firefly algorithm for combinatorial optimization. arXiv 2012, arXiv:1204.5165. [Google Scholar]
  56. Kabir, M.M.; Shahjahan, M.; Murase, K. A new local search based hybrid genetic algorithm for feature selection. Neurocomputing 2011, 74, 2914–2928. [Google Scholar] [CrossRef]
Figure 1. Sample wheat and weed images in the employed dataset.
Figure 1. Sample wheat and weed images in the employed dataset.
Mathematics 10 04421 g001
Figure 2. The updating process of the grey wolf optimization algorithm.
Figure 2. The updating process of the grey wolf optimization algorithm.
Mathematics 10 04421 g002
Figure 3. Tolerance given to the solutions that proceed in either direction toward or away from the destination for sine and cosine functions [41].
Figure 3. Tolerance given to the solutions that proceed in either direction toward or away from the destination for sine and cosine functions [41].
Mathematics 10 04421 g003
Figure 4. The proposed methodology for weed/wheat classification.
Figure 4. The proposed methodology for weed/wheat classification.
Mathematics 10 04421 g004
Figure 5. The transfer learning process.
Figure 5. The transfer learning process.
Mathematics 10 04421 g005
Figure 6. Residual, homoscedasticity, and QQ plots and heatmap of the ADSCFGWO and compared algorithms.
Figure 6. Residual, homoscedasticity, and QQ plots and heatmap of the ADSCFGWO and compared algorithms.
Mathematics 10 04421 g006
Figure 7. ROC, accuracy, and histogram plots of the ADSCFGWO and compared algorithms.
Figure 7. ROC, accuracy, and histogram plots of the ADSCFGWO and compared algorithms.
Mathematics 10 04421 g007
Figure 8. Residual, homoscedasticity, and QQ plots and heatmap of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ) based on convergence time.
Figure 8. Residual, homoscedasticity, and QQ plots and heatmap of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ) based on convergence time.
Mathematics 10 04421 g008
Figure 9. Convergence time of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Figure 9. Convergence time of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Mathematics 10 04421 g009
Figure 10. Histogram of convergence time of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Figure 10. Histogram of convergence time of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Mathematics 10 04421 g010
Figure 11. Convergence fitness of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Figure 11. Convergence fitness of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Mathematics 10 04421 g011
Figure 12. Residual, homoscedasticity, and QQ plots and heatmap of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ) based on convergence fitness.
Figure 12. Residual, homoscedasticity, and QQ plots and heatmap of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ) based on convergence fitness.
Mathematics 10 04421 g012
Figure 13. Histogram of convergence fitness of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Figure 13. Histogram of convergence fitness of ADSCFGWO’s parameters ( r 1 , r 2 , r 3 , r 4 , A 1 , A 2 , A 3 , C 1 , and C 2 ).
Mathematics 10 04421 g013
Table 1. Weed detection approaches published in the literature.
Table 1. Weed detection approaches published in the literature.
ReferenceTaskTarget CropModelPrecision
[3]Detection and classification of weedsUnspecifiedRF95%
[4]Canopy structure measurementAvocado treeRF96%
[5]Recognition of weed typesMaizeKNN, RF81%, 76.95%
[30]Early weed mappingSunflower, cottonRF87.90%
[31]Weed detection by UAVMaizeYOLOv398%
[24]Water aquatic vegetation monitoringStratiotes aloidesRF92.19%
[25]Mapping of land cover9 perennial cropsSVM84.80%
[26]Recognition of weed types8 weed plantsSVM92.35%
[27]Detection of weeds using shape featureSugar beetSVM95%
[28]Detection of weedsSoybeanSVM95.07%
[32]Weed detection using image processingChilliRF96%
[33]Mapping of weeds using images from UAVMaize, SunflowerSVM95.50%
Table 2. Configuration parameters of the proposed feature selection method.
Table 2. Configuration parameters of the proposed feature selection method.
ParameterValue
Iterations100
Agents10
α of Equation (20)0.99
β of Equation (20)0.01
θ [0, 12 π ]
a[−10, 10]
b[−10, 10]
Table 3. Configuration parameters of the optimization algorithms.
Table 3. Configuration parameters of the optimization algorithms.
AlgorithmParameterValue
GACross over0.9
Agents10
Iterations80
Selection mechanismRoulette wheel
Mutation ratio0.1
PSOAcceleration constants[2, 2]
Iterations80
Inertia W m i n , W m a x [0.6, 0.9]
Particles10
WOAr[0, 1]
Whales10
Iterations80
a2 to 0
GWOa2 to 0
Iterations80
Wolves10
FAIterations80
Fireflies10
Table 4. Evaluation metrics used in assessing the feature selection approach.
Table 4. Evaluation metrics used in assessing the feature selection approach.
MetricFormula
Average fitness size 1 M i = 1 M s i z e ( g * i )
Average error 1 M j = 1 M 1 N i = 1 N m s e ( C i , L i )
Standard deviation 1 M 1 i = 1 M g * i M e a n 2
Best fitness m i n i = 1 M g * i
Worst fitness m a x i = 1 M g * i
Mean 1 M i = 1 M g * i
Table 5. Evaluation metrics used in assessing the proposed optimized voting classifier.
Table 5. Evaluation metrics used in assessing the proposed optimized voting classifier.
MetricFormula
F1-score T P T P + 0.5 ( F P + F N )
Specificity (TNR) T N T N + F P
Accuracy T P + T N T P + T N + F P + F N
Sensitivity (TPR) T P T P + F N
Nvalue (NPV) T N T N + F N
Pvalue (PPV) T P T P + F P
Table 6. Evaluation of three deep networks for feature extraction.
Table 6. Evaluation of three deep networks for feature extraction.
VGGNetResNet-50AlexNet
Accuracy0.7690.8330.847
Specificity (TNR)0.8000.8000.783
Sensitivity (TPR)0.7140.8620.889
Nvalue (NPV)0.8330.8330.818
Pvalue (PPV)0.6670.8330.865
F-score0.6900.8470.877
Table 7. Evaluation of the proposed feature selection method and three other competing methods.
Table 7. Evaluation of the proposed feature selection method and three other competing methods.
bADSCFGWObGWObGWO_PSObPSObWAObFAbGA
Average select size0.6470.8470.9810.8471.0110.8820.790
Std fitness0.5800.5850.6030.5840.5860.6210.586
Average fitness0.7580.7740.7820.7720.7800.8240.785
Average error0.6950.7120.7510.7460.7450.7440.725
Worst fitness0.7580.7610.8460.8200.8200.8410.804
Best fitness0.6600.6940.7360.7530.7440.7430.689
Table 8. Evaluating the results achieved by three baseline machine learning models.
Table 8. Evaluating the results achieved by three baseline machine learning models.
KNNSVMNN
Accuracy0.8910.9210.935
Specificity (TNR)0.7430.8570.870
Sensitivity (TPR)0.9520.9520.971
Nvalue (NPV)0.8670.9000.943
Pvalue (PPV)0.8990.9300.930
F-score0.9250.9410.950
Table 9. Evaluation of the results achieved by optimizing the proposed voting classifier using the proposed optimization method and three other optimizers.
Table 9. Evaluation of the results achieved by optimizing the proposed voting classifier using the proposed optimization method and three other optimizers.
Voting (ADSCFGWO)Voting (WOA)Voting (GWO)Voting (GA)Voting (PSO)
Accuracy0.9770.9430.9450.9510.954
Specificity (TNR)0.9520.8700.8700.8700.870
Sensitivity (TPR)0.9840.9770.9770.9810.983
Nvalue (NPV)0.9430.9430.9430.9430.943
Pvalue (PPV)0.9870.9430.9450.9540.958
F-score0.9860.9600.9610.9670.970
Table 10. Statistical analysis of the achieved classification results using the proposed optimized voting ensemble model.
Table 10. Statistical analysis of the achieved classification results using the proposed optimized voting ensemble model.
ADSCFGWOWOAGWOGAPSO
Number of values2020202020
25% Percentile0.97740.9430.9450.9510.954
75% Percentile0.97740.9430.9450.9510.954
Std. error of mean0.00010.0010.0010.0010.001
Std. deviation0.00040.0030.0030.0040.003
Mean0.97750.94390.9450.9500.954
Minimum0.97740.9340.9350.9380.944
Maximum0.97940.9510.9560.9550.964
Median0.97740.9430.9450.9510.954
Range0.0020.0170.0210.01720.020
Upper 95% CI of mean0.97770.9450.9470.9520.956
Lower 95% CI of mean0.97730.9420.9440.9490.953
Coefficient of variation0.0501%0.353%0.366%0.397%0.340%
Geometric SD factor1.0011.0041.0041.0041.003
Geometric mean0.97750.9440.9450.9500.954
Upper 95% CI of harm. mean0.97770.9450.9470.9520.956
Lower 95% CI of harm. mean0.97730.9420.9440.9490.953
Sum19.5518.8818.9019.0119.09
Table 11. ANOVA test of the achieved classification results using the optimized voting ensemble model.
Table 11. ANOVA test of the achieved classification results using the optimized voting ensemble model.
SSDFMSF (DFn, DFd)p Value
Treatment0.0149640.003739F (4, 95) = 389.0p < 0.0001
Residual0.0009132950.000009612
Total0.0158799
Table 12. Wilcoxon signed-rank test of the results achieved by the proposed optimized voting classifier.
Table 12. Wilcoxon signed-rank test of the results achieved by the proposed optimized voting classifier.
ADSCFGWOWOAGWOGAPSO
Theoretical median00000
Actual median0.97740.94340.94490.95130.9544
Number of values2020202020
Wilcoxon signed-rank test
p value (two-tailed)<0.0001<0.0001<0.0001<0.0001<0.0001
Sum of positive ranks210210210210210
Sum of signed ranks (W)210210210210210
Sum of negative ranks00000
Exact or estimate?ExactExactExactExactExact
p value summary********************
Discrepancy0.97740.94340.94490.95130.9544
Significant (alpha = 0.05)?YesYesYesYesYes
Table 13. Convergence time results (in seconds) for different values of ADSCFGWO’s parameters (1).
Table 13. Convergence time results (in seconds) for different values of ADSCFGWO’s parameters (1).
r 1 r 2 r 3 r 4
ValuesTimeValuesTimeValuesTimeValuesTime
0.0512.210.0511.990.0511.820.0511.89
0.1012.210.1011.640.1012.210.1011.63
0.1512.360.1512.150.1512.010.1511.61
0.2011.820.2012.200.2011.980.2012.32
0.2511.770.2512.040.2512.120.2512.02
0.3011.980.3011.730.3011.590.3012.15
0.3512.310.3511.590.3512.400.3512.00
0.4012.000.4012.350.4011.630.4011.78
0.4512.440.4511.720.4512.060.4512.44
0.5012.070.5012.310.5011.610.5011.73
0.5511.640.5511.880.5512.350.5512.45
0.6011.650.6011.810.6012.060.6012.05
0.6512.200.6511.800.6511.620.6512.04
0.7012.140.7011.770.7011.760.7012.44
0.7511.610.7511.760.7511.580.7512.24
0.8012.200.8011.680.8012.150.8012.26
0.8511.760.8511.670.8511.620.8511.97
0.9011.830.9011.910.9011.680.9012.16
0.9511.780.9512.360.9511.940.9511.80
1.0011.951.0012.251.0011.791.0012.15
Table 14. Convergence time results (in seconds) for different values of ADSCFGWO’s parameters (2).
Table 14. Convergence time results (in seconds) for different values of ADSCFGWO’s parameters (2).
A 1 A 2 A 3 C 1 C 2
ValuesTimeValuesTimeValuesTimeValuesTimeValuesTime
0.0511.630.1011.780.1011.600.1011.680.1011.70
0.1012.400.2011.730.2011.880.2012.060.2012.21
0.1512.390.3011.580.3012.410.3011.620.3011.75
0.2011.830.4011.630.4012.300.4012.260.4012.37
0.2511.900.5011.770.5011.620.5011.870.5012.38
0.3012.020.6012.240.6012.110.6012.270.6011.98
0.3511.880.7012.360.7011.670.7012.170.7011.65
0.4012.120.8011.610.8012.210.8012.110.8012.32
0.4512.380.9012.320.9011.880.9012.240.9011.85
0.5012.081.0011.671.0011.931.0011.721.0012.32
0.5511.691.1011.661.1012.171.1012.261.1012.09
0.6011.901.2011.641.2012.101.2011.631.2012.27
0.6511.971.3011.891.3011.711.3011.701.3012.23
0.7012.391.4012.101.4011.841.4011.961.4012.18
0.7511.751.5012.241.5011.841.5012.351.5012.29
0.8012.331.6012.441.6012.141.6011.681.6012.41
0.8511.631.7012.341.7011.771.7012.031.7012.04
0.9012.401.8011.951.8012.121.8011.611.8012.13
0.9512.191.9012.211.9012.291.9012.431.9011.65
1.0012.292.0011.682.0011.922.0012.042.0012.41
Table 15. Minimization results for different values of ADSCFGWO’s parameters (1).
Table 15. Minimization results for different values of ADSCFGWO’s parameters (1).
r 1 r 2 r 3 r 4
ValuesFitnessValuesFitnessValuesFitnessValuesFitness
0.05117.510.05116.110.05117.040.05116.53
0.10117.370.10117.580.10115.640.10116.46
0.15115.860.15115.450.15116.760.15117.46
0.20116.210.20117.570.20115.540.20116.39
0.25115.610.25117.610.25116.950.25116.76
0.30115.890.30117.020.30117.420.30116.16
0.35116.520.35117.570.35116.800.35116.15
0.40115.600.40116.540.40116.810.40117.11
0.45116.000.45117.510.45116.210.45116.09
0.50116.130.50115.550.50115.460.50116.99
0.55117.470.55117.540.55117.380.55116.64
0.60115.760.60116.780.60116.210.60117.15
0.65116.360.65115.880.65117.050.65116.83
0.70115.800.70117.000.70116.630.70116.90
0.75116.670.75116.390.75116.490.75116.97
0.80117.290.80116.460.80116.620.80116.72
0.85117.320.85115.570.85116.920.85116.10
0.90115.820.90117.430.90117.280.90116.42
0.95115.400.95117.280.95117.220.95116.52
1.00115.501.00116.751.00116.081.00115.64
Table 16. Minimization results for different values of ADSCFGWO’s parameters (2).
Table 16. Minimization results for different values of ADSCFGWO’s parameters (2).
A 1 A 2 A 3 C 1 C 2
ValuesFitnessValuesFitnessValuesFitnessValuesFitnessValuesFitness
0.05116.770.10115.880.10116.870.10116.450.10117.25
0.10116.620.20117.050.20116.450.20117.060.20115.41
0.15117.380.30117.580.30116.970.30116.050.30115.71
0.20117.530.40115.960.40117.580.40115.970.40117.01
0.25116.930.50115.640.50116.530.50117.660.50115.44
0.30117.540.60115.480.60116.670.60116.820.60116.53
0.35116.240.70116.610.70116.470.70116.930.70115.99
0.40116.830.80117.020.80116.670.80116.160.80117.20
0.45115.750.90116.780.90116.390.90117.170.90115.40
0.50117.031.00115.741.00116.781.00117.241.00116.36
0.55115.361.10115.431.10116.821.10117.021.10115.67
0.60116.751.20115.821.20117.171.20117.281.20115.84
0.65116.771.30116.931.30116.631.30115.831.30117.19
0.70116.931.40115.501.40115.761.40116.471.40116.32
0.75115.981.50115.921.50116.401.50116.041.50116.02
0.80116.821.60117.511.60116.881.60115.791.60117.02
0.85115.551.70117.361.70115.551.70115.961.70116.86
0.90115.791.80117.351.80116.521.80117.101.80116.63
0.95116.551.90115.801.90117.281.90116.051.90116.78
1.00117.502.00116.912.00115.822.00116.442.00116.54
Table 17. ANOVA test analyzing the convergence time.
Table 17. ANOVA test analyzing the convergence time.
SSDFMSF (DFn, DFd)p Value
Treatment0.760380.09504F (8, 171) = 1.336p = 0.002288
Residual12.171710.07115
Total12.93179
Table 18. Wilcoxon signed-rank test of the convergence time.
Table 18. Wilcoxon signed-rank test of the convergence time.
r 1 r 2 r 3 r 4 A 1 A 2 A 3 C 1 C 2
Number of values202020202020202020
Actual mean1211.9411.912.0612.0611.9511.9811.9912.12
Theoretical mean000000000
dfdf = 19df = 19df = 19df = 19df = 19df = 19df = 19df = 19df = 19
tt = 209.6t = 208.2t = 200.1t = 207.8t = 196.0t = 175.3t = 222.7t = 195.7t = 205.8
p value (two-tailed)<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001
Discrepancy1211.9411.912.0612.0611.9511.9811.9912.12
Significant (alpha = 0.05)?YesYesYesYesYesYesYesYesYes
SEM of discrepancy0.05720.05730.05940.05800.06150.06810.05380.06120.0588
SD of discrepancy0.25610.25640.2660.25960.27520.30480.24060.27390.2633
R squared0.99960.99960.99950.99960.99950.99940.99960.99950.9996
95% confidence (From)11.8811.8211.7811.9411.9311.8111.8711.8611.99
95% confidence (To)12.1212.0612.0312.1812.1912.0912.0912.1212.24
Table 19. Statistical analysis of the convergence time.
Table 19. Statistical analysis of the convergence time.
r 1 r 2 r 3 r 4 A 1 A 2 A 3 C 1 C 2
Number of values202020202020202020
Minimum11.6111.611.5811.6211.6411.5811.6111.6111.65
Range0.8300.7600.8200.8300.7600.8600.8000.8200.760
25% Percentile11.7811.7311.6211.8311.8511.6711.7911.6911.88
75% Percentile12.2112.1912.1112.2612.3712.2512.1712.2612.32
Mean12.011.9411.9012.0612.0611.9511.9811.9912.12
Median11.9911.8511.8912.0512.0511.8411.9312.0412.20
Maximum12.4512.3712.4112.4612.4112.4512.4112.4312.42
Std. error of mean0.0570.0570.0590.0580.0610.0680.0530.0610.058
Std. deviation0.2560.2560.2660.2590.2750.3040.2400.2730.263
Sum240.0238.7238.0241.2241.3239.0239.6239.8242.3
Table 20. Wilcoxon signed-rank test of the fitness of the proposed ADSCFGWO algorithm.
Table 20. Wilcoxon signed-rank test of the fitness of the proposed ADSCFGWO algorithm.
r 1 r 2 r 3 r 4 A 1 A 2 A 3 C 1 C 2
Number of values202020202020202020
Actual mean116.3116.8116.6116.6116.6116.4116.6116.6116.4
Theoretical mean000000000
dfdf = 19df = 19df = 19df = 19df = 19df = 19df = 19df = 19df = 19
tt = 721.8t = 694.1t = 872.0t = 1178t = 791.3t = 685.0t = 1051t = 903.7t = 818.3
Discrepancy116.3116.8116.6116.6116.6116.4116.6116.6116.4
p value (two-tailed)<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001<0.0001
Significant (alpha = 0.05)?YesYesYesYesYesYesYesYesYes
SEM of discrepancy0.16110.16830.13370.098960.14740.16990.11090.1290.1422
SD of discrepancy0.72060.75250.59810.44260.65920.760.4960.57690.6359
R squared111111111
95% confidence (from)116.0116.4116.4116.4116.3116.1116.4116.3116.1
95% confidence (to)116.6117.1116.9116.8116.9116.8116.8116.8116.7
Table 21. ANOVA test of the fitness of the proposed ADSCFGWO algorithm.
Table 21. ANOVA test of the fitness of the proposed ADSCFGWO algorithm.
SSDFMSF (DFn, DFd)p Value
Treatment3.74980.4686F (8, 171) = 1.160p = 0.003259
Residual69.051710.4038
Total72.8179
Table 22. Statistical analysis of the fitness achieved by the proposed optimization algorithm.
Table 22. Statistical analysis of the fitness achieved by the proposed optimization algorithm.
r 1 r 2 r 3 r 4 A 1 A 2 A 3 C 1 C 2
Number of values202020202020202020
Range2.1082.1581.9671.8242.1762.1482.0291.871.851
25% Percentile115.8116.2116.2116.2116.1115.8116.4116.0115.7
75% Percentile117.1117.5117.1117.0117.0117.0116.9117.1117.0
Minimum115.4115.5115.5115.6115.4115.4115.6115.8115.4
Mean116.3116.8116.6116.6116.6116.4116.6116.6116.4
Median116.1116.9116.8116.6116.8116.3116.7116.5116.4
Maximum117.5117.6117.4117.5117.5117.6117.6117.7117.3
Std. error of mean0.1610.1680.1330.0980.1470.1690.1110.1290.142
Std. deviation0.7210.7520.5980.4420.6590.7600.4960.5770.636
Sum232623362333233223332328233223322327
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

El-Kenawy, E.-S.M.; Khodadadi, N.; Mirjalili, S.; Makarovskikh, T.; Abotaleb, M.; Karim, F.K.; Alkahtani, H.K.; Abdelhamid, A.A.; Eid, M.M.; Horiuchi, T.; et al. Metaheuristic Optimization for Improving Weed Detection in Wheat Images Captured by Drones. Mathematics 2022, 10, 4421. https://doi.org/10.3390/math10234421

AMA Style

El-Kenawy E-SM, Khodadadi N, Mirjalili S, Makarovskikh T, Abotaleb M, Karim FK, Alkahtani HK, Abdelhamid AA, Eid MM, Horiuchi T, et al. Metaheuristic Optimization for Improving Weed Detection in Wheat Images Captured by Drones. Mathematics. 2022; 10(23):4421. https://doi.org/10.3390/math10234421

Chicago/Turabian Style

El-Kenawy, El-Sayed M., Nima Khodadadi, Seyedali Mirjalili, Tatiana Makarovskikh, Mostafa Abotaleb, Faten Khalid Karim, Hend K. Alkahtani, Abdelaziz A. Abdelhamid, Marwa M. Eid, Takahiko Horiuchi, and et al. 2022. "Metaheuristic Optimization for Improving Weed Detection in Wheat Images Captured by Drones" Mathematics 10, no. 23: 4421. https://doi.org/10.3390/math10234421

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop